local cjson = require "cjson"
local utils = require "utils"

local client = {}

function client.send(sock, uid, msg)
    local cmd = {
        name="sendmessage",
        data={
            uid=uid,
            package=msg
        }
    }
    local data = utils.packjson(cmd)
    return sock:send(data)
end

return client
